﻿@model ChangePasswordModel
@using Nop.Web.Models.Customer;
@{
    Layout = "~/Views/Shared/_MyHUB.cshtml";

    //title
    Html.AddTitleParts(T("PageTitle.Account").Text);
}

@section left
{
    @Html.Partial("MyAccountNavigation", Model.NavigationModel, new ViewDataDictionary())
}

<div class="page account-page change-password-page customer-info-page">

    <h1 class="page-title">@T("Account.MyAccount") - @T("Account.ChangePassword")</h1>
    @using (Html.BeginForm())
    {
        @Html.AntiForgeryToken()
        <div class="message-error">
            @Html.ValidationSummary(true)
        </div>
        if (!String.IsNullOrEmpty(Model.Result))
        {

            <div class="result">
                @Model.Result
            </div>
        }
        <div class="input-row input-row-left">
            <div class="info-label">
                @Html.RequiredHint()
                @Html.LabelFor(model => model.OldPassword)
            </div>
            <div class="info-input">
                @Html.EditorFor(model => model.OldPassword)
            </div>
            @Html.ValidationMessageFor(model => model.OldPassword)
        </div>
        <div class="input-row input-row-left">
            <div class="info-label">
                @Html.RequiredHint()
                @Html.LabelFor(model => model.NewPassword)
            </div>
            <div class="info-input">
                @Html.EditorFor(model => model.NewPassword)
            </div>
            @Html.ValidationMessageFor(model => model.NewPassword)
        </div>
        <div class="input-row input-row-left">
            <div class="info-label">
                @Html.RequiredHint()
                @Html.LabelFor(model => model.ConfirmNewPassword)
            </div>
            <div class="info-input">
                @Html.EditorFor(model => model.ConfirmNewPassword)
            </div> 
            @Html.ValidationMessageFor(model => model.ConfirmNewPassword)
        </div>
        <div class="buttons">
            <input type="submit" class="button-red change-password-button" value="@T("Account.ChangePassword.Button")" />
        </div>
    }
</div>